package com.uzai.console.web.tb.tbactivityregtoken;

import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport;
import com.github.xiaoymin.knife4j.annotations.ApiSort;
import com.uzai.common.exception.BusinessException;
import com.uzai.console.annotation.SystemLogType;
import com.uzai.console.dto.tb.tbtoken.*;
import com.uzai.console.enums.OperationTypeEnum;
import com.uzai.console.enums.SystemModelEnum;
import com.uzai.console.service.tb.tbtoken.TbTokenService;
import com.uzai.console.vo.tb.tbactivityregtoken.TbActivityRegTokenVo;
import com.uzai.console.vo.tb.tbtoken.TbTokenAuthUrlVo;
import com.uzai.console.vo.tb.tbtoken.TbTokenInfoVo;
import com.uzai.console.vo.tb.tbtoken.TbTokenPageVo;
import com.uzai.console.web.BaseController;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;

import java.util.Objects;

/**
 * 淘宝联盟
 * @author liuqi
 * @date 2021年08月16日 15:11
 */
@Api(value = "618赛马",tags = "淘宝|618赛马")
@ApiSort(9)
@RestController
public class TbActivityRegTokenController extends BaseController {
    private Logger logger = LoggerFactory.getLogger(TbActivityRegTokenController.class);

    @Autowired
    private TbTokenService tbTokenService;

    @ApiOperation(value = "分页查询618赛马列表", notes = "分页查询618赛马列表", response = TbActivityRegTokenVo.class)
    @ApiOperationSupport(order = 1)
    @PostMapping("/tbActivityRegToken/findByPage")
    public Object findTbActivityRegTokenPage(@RequestBody TbTokenQuery tbTokenQuery){
        //查询淘宝
        tbTokenQuery.setType(0);
        //查询返利
        tbTokenQuery.setTurnlink(0);
        return tbTokenService.findTbActivityRegTokenList(tbTokenQuery);
    }

}
